-
-
Notifications
You must be signed in to change notification settings - Fork 45.6k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add solution to project_euler/problem_060 #8678
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Click here to look at the relevant links ⬇️
🔗 Relevant Links
Repository:
Python:
Automated review generated by algorithms-keeper. If there's any problem regarding this review, please open an issue about it.
algorithms-keeper
commands and options
algorithms-keeper actions can be triggered by commenting on this PR:
@algorithms-keeper review
to trigger the checks for only added pull request files@algorithms-keeper review-all
to trigger the checks for all the pull request files, including the modified files. As we cannot post review comments on lines not part of the diff, this command will post all the messages in one comment.NOTE: Commands are in beta and so this feature is restricted only to a member or owner of the organization.
project_euler/problem_060/sol1.py
Outdated
COUNTER = False | ||
|
||
|
||
def get_order(n: int) -> int: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please provide descriptive name for the parameter: n
project_euler/problem_060/sol1.py
Outdated
return True | ||
|
||
|
||
def is_prime(n) -> bool: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please provide descriptive name for the parameter: n
Please provide type hint for the parameter: n
@ignacio-gn use |
I noticed that ruff fails for files that were already present in the repository, which I did not edit. Because of that, I decided to leave these files intact. I can attempt to fix them or rebase once they are fixed. Below is the error message:
|
The first two errors suggest that we should use format specifiers instead of percent format. So we'll need to update the code in The third error suggests that there may be a possible injection detected. we should check the code in Once we have made the necessary changes, you can run |
@ignacio-gn I have made PR #8680 and #8679 to address above issue for both files, can you merge that two PR in one, rohan472000:patch-8 into rohan472000:patch-9 because I cant see both branches in my local after fork. |
for more information, see https://pre-commit.ci
for more information, see https://pre-commit.ci
I have merged both PR into one #8680 |
…criminant_analysis.py
commenting out that line 402 is working for now, which is good, but what alternative can we put there instead of that line??? |
I have commented out the system call to clear the console on I haven't contributed to |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
as #8680 is merged so there is no need to make any changes in those files, just run github actions again , it should work fine.
…ms#8680) * Update rsa_cipher.py by replacing %s with {} * Update rsa_cipher.py * [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci * Update linear_discriminant_analysis.py * [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci * Update linear_discriminant_analysis.py * Update linear_discriminant_analysis.py * [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci * Update linear_discriminant_analysis.py * Update linear_discriminant_analysis.py * [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci * Update linear_discriminant_analysis.py * Update machine_learning/linear_discriminant_analysis.py Co-authored-by: Christian Clauss <[email protected]> * Update linear_discriminant_analysis.py * updated --------- Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com> Co-authored-by: Christian Clauss <[email protected]>
Describe your change:
Add a solution to problem 60 of project Euler
Checklist:
Fixes: #{$ISSUE_NO}
.